#打印杨辉三角

#        请在此处添加代码       #
# *************begin************#
n=input()
result=list()
row=0
col=0
while(row<int(n)):
    if row==0:
        result.append([1])
    else:
        rowt=list()
        while(col<=row):
            if(col==0 or col==row):
                rowt.append(1)
            else:
                a=result[row-1][col-1]+result[row-1][col]
                rowt.append(a)
            col+=1
        result.append(rowt)
        row+=1
        col=0

for a in result:
    for b in a:
        print(b,end='\t')
    print()

print(result)
# **************end*************#
